package com.huatai.bpmn.entity;

import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import org.checkerframework.common.aliasing.qual.Unique;

import javax.validation.constraints.NotNull;
import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;
import java.util.List;

/**
 * <p>
 *	表格表头配置实体
 * </p>
 *
 * @author yxy
 * @since 2023-07-07
 */
@Data
@TableName("yy_basic")
@ApiModel(value = "表格表头配置实体",description = "表格表头配置实体")
public class YYBasicEntity implements Serializable {


    @TableId(value = "id", type = IdType.ASSIGN_ID)
    private String id;

    private LocalDateTime createTime;

    private LocalDateTime updateTime;

    private LocalDateTime deleteTime;

    /**
     * key类型
     */
	@ApiModelProperty("key类型")
	@NotNull(message = "字段类型不能为空")
    private String type;

    /**
     * key
     */
	@ApiModelProperty("key")
	@NotNull(message = "字段别名不能为空")
	@Unique
    private String jsonKey;

    /**
     * key中文名
     */
	@ApiModelProperty("key中文名")
	@NotNull(message = "字段名不能为空")
    private String jsonValue;

    /**
     * 字段所处位置
     */
	@ApiModelProperty("字段所处位置")
	@NotNull(message = "应用表单不能为空")
    private String place;

    /**
     * 备注
     */
	@ApiModelProperty("备注")
    private String remarks;


    /**
     * 排序
     */
	@ApiModelProperty("排序")
	@NotNull(message = "排序不能为空")
    private BigDecimal sort;

    /**
     * 1.true、0.false 必填项
     */
	@ApiModelProperty("1.true、0.false 必填项")
	@NotNull(message = "必填不能为空")
    private Boolean required;

    /**
     * 下拉选择项
     */
	@ApiModelProperty("下拉选择项")
    private String selectItem;


    private String pid;

	@TableField(exist = false)
	private List<YYBasicEntity> children;

	@ApiModelProperty("是否提醒 0不提醒 1提醒，提醒内容为备注里面的内容")
	private Integer hint=0;
}
